package org.baeta.model;

import java.util.Date;

/**
 * {"weatherObservation": {
 * "weatherCondition": "n/a",
 * "clouds": "scattered clouds",
 * "observation": "LPPT 261130Z VRB06KT 9999 SCT030 20/07 Q1010",
 * "ICAO": "LPPT",
 * "elevation": 123,
 * "countryCode": "PT",
 * "cloudsCode": "SCT",
 * "lng": -9.116666666666667,
 * "temperature": "20",
 * "dewPoint": "7",
 * "windSpeed": "06",
 * "humidity": 42,
 * "stationName": "Lisboa / Portela",
 * "datetime": "2012-09-26 11:30:00",
 * "lat": 38.766666666666666,
 * "hectoPascAltimeter": 1010
 * }}
 *
 * {"weatherObservations":[{"clouds":"clouds and visibility OK","weatherCondition":"n/a","observation":"LPPT 262230Z 36009KT CAVOK 17/10 Q1011","windDirection":360,"ICAO":"LPPT","cloudsCode":"CAVOK","lng":-9.116666666666667,"temperature":"17","dewPoint":"10","windSpeed":"09","humidity":63,"stationName":"Lisboa / Portela","datetime":"2012-09-26 22:30:00","lat":38.766666666666666,"hectoPascAltimeter":1011},{"clouds":"few clouds","weatherCondition":"n/a","observation":"LPOV 262200Z VRB01KT 9999 FEW022 13/12 Q1012","ICAO":"LPOV","cloudsCode":"FEW","lng":-8.65,"temperature":"13","dewPoint":"12","windSpeed":"01","humidity":93,"stationName":"Ovar Mil.","datetime":"2012-09-26 22:00:00","lat":40.916666666666664,"hectoPascAltimeter":1012},{"clouds":"few clouds","weatherCondition":"n/a","observation":"LPBJ 262200Z 32006KT 9999 FEW025 17/13 Q1011","windDirection":320,"ICAO":"LPBJ","cloudsCode":"FEW","lng":-7.866666666666667,"temperature":"17","dewPoint":"13","windSpeed":"06","humidity":77,"stationName":"Beja","datetime":"2012-09-26 22:00:00","lat":38.016666666666666,"hectoPascAltimeter":1011},{"clouds":"few clouds","weatherCondition":"n/a","observation":"LPFR 262230Z 34005KT 9999 FEW015 18/16 Q1010","windDirection":340,"ICAO":"LPFR","cloudsCode":"FEW","lng":-7.966666666666667,"temperature":"18","dewPoint":"16","windSpeed":"05","humidity":88,"stationName":"Faro / Aeroporto","datetime":"2012-09-26 22:30:00","lat":37.016666666666666,"hectoPascAltimeter":1010},{"clouds":"few clouds","weatherCondition":"n/a","observation":"LPMR 262200Z VRB01KT 9999 FEW022 14/11 Q1012","ICAO":"LPMR","cloudsCode":"FEW","lng":-8.866666666666667,"temperature":"14","dewPoint":"11","windSpeed":"01","humidity":82,"stationName":"Monte Real Mil.","datetime":"2012-09-26 22:00:00","lat":39.81666666666667,"hectoPascAltimeter":1012},{"clouds":"scattered clouds","weatherCondition":"n/a","observation":"LPAR 261000Z VRB02KT 9999 SCT025 20/12 Q1009","ICAO":"LPAR","cloudsCode":"SCT","lng":-9.033333333333333,"temperature":"20","dewPoint":"12","windSpeed":"02","humidity":60,"stationName":"ALVERCA","datetime":"2012-09-26 10:00:00","lat":38.88333333333333,"hectoPascAltimeter":1009},{"clouds":"clouds and visibility OK","weatherCondition":"n/a","observation":"LPMT 262200Z 36006KT CAVOK 17/12 Q1012","windDirection":360,"ICAO":"LPMT","cloudsCode":"CAVOK","lng":-9.05,"temperature":"17","dewPoint":"12","windSpeed":"06","humidity":72,"stationName":"Montijo Mil.","datetime":"2012-09-26 22:00:00","lat":38.7,"hectoPascAltimeter":1012},{"clouds":"few clouds","weatherCondition":"n/a","observation":"LPPR 262230Z 01002KT 9999 FEW020 12/12 Q1013","windDirection":10,"ICAO":"LPPR","cloudsCode":"FEW","lng":-8.666666666666666,"temperature":"12","dewPoint":"12","windSpeed":"02","humidity":100,"stationName":"Porto / Pedras Rubras","datetime":"2012-09-26 22:30:00","lat":41.21666666666667,"hectoPascAltimeter":1013},{"clouds":"scattered clouds","weatherCondition":"n/a","observation":"LPST 261000Z 31006KT 280V350 9999 SCT020 18/11 Q1010","windDirection":310,"ICAO":"LPST","cloudsCode":"SCT","lng":-9.316666666666666,"temperature":"18","dewPoint":"11","windSpeed":"06","humidity":63,"stationName":"Sintra Mil.","datetime":"2012-09-26 10:00:00","lat":38.81666666666667,"hectoPascAltimeter":1010},{"clouds":"few clouds","weatherCondition":"n/a","observation":"LEBZ 261000Z 29005KT 240V340 9999 FEW018 SCT030 18/12 Q1010","windDirection":290,"ICAO":"LEBZ","cloudsCode":"FEW","lng":-6.816666666666666,"temperature":"18","dewPoint":"12","windSpeed":"05","humidity":67,"stationName":"Badajoz / Talavera La Real","datetime":"2012-09-26 10:00:00","lat":38.86666666666667,"hectoPascAltimeter":1010}]}
 *
 * @author <a href="mailto:rui.baeta@gmail.com">Rui Baeta</a>
 */
public class WeatherObservation extends AbstractBean
{
    private String observation;
    private Date observationTime;
    private String stationName;
    private String icaoCode;
    private String countryCode;
    private int elevation;
    private double latitude;
    private double longitude;
    private double temperature;
    private double dewPoint;
    private double humidity;
    private String clouds;
    private String weatherCondition;
    private String windSpeed;
    private int windDirection;

    /** @return the observation */
    public String getObservation()
    {
        return observation;
    }

    /** @param observation the observation to set */
    public void setObservation(String observation)
    {
        this.observation = observation;
    }

    /** @return the observationTime */
    public Date getObservationTime()
    {
        return observationTime;
    }

    /** @param observationTime the observationTime to set */
    public void setObservationTime(Date observationTime)
    {
        this.observationTime = observationTime;
    }

    /** @return the stationName */
    public String getStationName()
    {
        return stationName;
    }

    /** @param stationName the stationName to set */
    public void setStationName(String stationName)
    {
        this.stationName = stationName;
    }

    /** @return the icaoCode */
    public String getIcaoCode()
    {
        return icaoCode;
    }

    /** @param icaoCode the icaoCode to set */
    public void setIcaoCode(String icaoCode)
    {
        this.icaoCode = icaoCode;
    }

    /** @return the countryCode */
    public String getCountryCode()
    {
        return countryCode;
    }

    /** @param countryCode the countryCode to set */
    public void setCountryCode(String countryCode)
    {
        this.countryCode = countryCode;
    }

    /** @return the elevation */
    public int getElevation()
    {
        return elevation;
    }

    /** @param elevation the elevation to set */
    public void setElevation(int elevation)
    {
        this.elevation = elevation;
    }

    /** @return the latitude */
    public double getLatitude()
    {
        return latitude;
    }

    /** @param latitude the latitude to set */
    public void setLatitude(double latitude)
    {
        this.latitude = latitude;
    }

    /** @return the longitude */
    public double getLongitude()
    {
        return longitude;
    }

    /** @param longitude the longitude to set */
    public void setLongitude(double longitude)
    {
        this.longitude = longitude;
    }

    /** @return the temperature */
    public double getTemperature()
    {
        return temperature;
    }

    /** @param temperature the temperature to set */
    public void setTemperature(double temperature)
    {
        this.temperature = temperature;
    }

    /** @return the dewPoint */
    public double getDewPoint()
    {
        return dewPoint;
    }

    /** @param dewPoint the dewPoint to set */
    public void setDewPoint(double dewPoint)
    {
        this.dewPoint = dewPoint;
    }

    /** @return the humidity */
    public double getHumidity()
    {
        return humidity;
    }

    /** @param humidity the humidity to set */
    public void setHumidity(double humidity)
    {
        this.humidity = humidity;
    }

    /** @return the clouds */
    public String getClouds()
    {
        return clouds;
    }

    /** @param clouds the clouds to set */
    public void setClouds(String clouds)
    {
        this.clouds = clouds;
    }

    /** @return the weatherCondition */
    public String getWeatherCondition()
    {
        return weatherCondition;
    }

    /** @param weatherCondition the weatherCondition to set */
    public void setWeatherCondition(String weatherCondition)
    {
        this.weatherCondition = weatherCondition;
    }

    /** @return the windSpeed */
    public String getWindSpeed()
    {
        return windSpeed;
    }

    /** @param windSpeed the windSpeed to set */
    public void setWindSpeed(String windSpeed)
    {
        this.windSpeed = windSpeed;
    }

    public int getWindDirection()
    {
        return windDirection;
    }

    public void setWindDirection(int windDirection)
    {
        this.windDirection = windDirection;
    }

    @Override
    public String toString()
    {
        return String.format("WeatherObservation{observation='%s', observationTime=%s, stationName='%s', icaoCode='%s', countryCode='%s', elevation=%d, latitude=%s, longitude=%s, temperature=%s, dewPoint=%s, humidity=%s, clouds='%s', weatherCondition='%s', windSpeed='%s'}",
                             observation, observationTime, stationName, icaoCode, countryCode, elevation, latitude, longitude, temperature, dewPoint, humidity, clouds, weatherCondition, windSpeed);
    }
}
